/**
 * Copyright (C) 2025 pony working team
 * SPDX-License-Identifier: MulanPSL-2.0
 */

/* define to prevent recursive inclusion -------------------------------------*/
#ifndef __PONY_VLOG_BUFFER_H__
#define __PONY_VLOG_BUFFER_H__

/* includes (standard library, system) ---------------------------------------*/
#include <stdio.h>
/* includes (other library) --------------------------------------------------*/
/* includes (project) --------------------------------------------------------*/
#include <x_config.h>
/* includes (local) ----------------------------------------------------------*/

#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */

/* defines -------------------------------------------------------------------*/
/* typedefs ------------------------------------------------------------------*/
/* macro ---------------------------------------------------------------------*/

#ifdef CONFIG_VLOG_MSG
extern void vlog_buffer(FILE *stream, const uint8_t *buf, int len, int indent);
#else
#define vlog_buffer(stream, buf, len, indent)
#endif

#define vlog_msg(buf, len) vlog_buffer(stdout, buf, len, 0)

#define VLOG_M vlog_msg

/* inlines -------------------------------------------------------------------*/
/* externs -------------------------------------------------------------------*/

#ifdef __cplusplus
}
#endif /* __cplusplus */

#endif /* __PONY_VLOG_BUFFER_H__ */
